package com.lxh.prototype;

/**
 * 原型模式
 */
public class Main {
    public static void main(String[] args) {
        Mail mail = new Mail(new AdvTemplate());
        mail.setTail("XX银行版权所有");

        for (int i = 0; i < 6; i++) {
            Mail clone = mail.clone();
            clone.setAppellation(i + "女士");
            clone.setReceiver(i + "@123.com");
            System.out.println(mail.getSubject() + "发送成功");
        }
    }
}
